package wpmp.security.client.log;

import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;

public abstract class LogUtil {
	static Log DEFAULT_LOG;

	static {
		DEFAULT_LOG = AppContextLogFactory.getLog();
	}

	public static Log getLog(final Class<?> clazz) {
		return LogFactory.getLog(clazz);
	}

	public static Log getLog(final String name) {
		return LogFactory.getLog(name);
	}

	public static Log getLog() {
		return DEFAULT_LOG != null ? DEFAULT_LOG : (DEFAULT_LOG = AppContextLogFactory.getLog());
	}

}
